package j03zuoye.pengzhuang;

public class RectTest {
    public static void main(String[] args) {
        Rectangle r1 = new Rectangle(
                new Point(0,3),
                4,
                3
        );
        Rectangle r2 = new Rectangle(
                new Point(3,3),
                4,
                3
        );
        //是否碰撞
        boolean isHit = r1.isIntersect(r2);
        System.out.println(isHit?"碰撞成功":"没有碰撞");
    }
}
